package com.stable.enums;

public enum RunLogBizTypeEnum {
	TRADE_CAL(1, "交易日历同步", true),
	STOCK_LIST(2, "基础code列表同步",true),
	PRO_BAR_HISTORY(3, "通用历史数据列表包含250日线数据",true),
	PRO_BAR_HORIZONTAL(4, "水平涨跌弧度分析",true),
	PRO_BAR_RECORDLEVELS(5, "阶段新高分析",true),
	THS_TOPIC_BASIC(6, "更新公司亮点质押等数据",false),
	FIVE_FINANCE_ANALYZE(7, "5年财务数据分析",true),
	NEW_FINANCE(8, "财务数据同步",true),
	THREE_FINANCE_ANALYZE(9, "3年财务数据分析",true),
	EAST_HSGTCG(10, "沪深港通持股",true);

	public int bcode;
	public String btypeName;
	boolean successNotify;


	private RunLogBizTypeEnum(int c, String n, boolean successNotify) {
		this.bcode = c;
		this.btypeName = n;
		this.successNotify = successNotify;
	}

	public int getBcode() {
		return bcode;
	}

	public void setBcode(int bcode) {
		this.bcode = bcode;
	}

	public String getBtypeName() {
		return btypeName;
	}

	public void setBtypeName(String btypeName) {
		this.btypeName = btypeName;
	}


	public boolean isSuccessNotify() {
		return successNotify;
	}

	public void setSuccessNotify(boolean successNotify) {
		this.successNotify = successNotify;
	}

	public static RunLogBizTypeEnum getRunLogBizTypeEnum(int code) {
		for (RunLogBizTypeEnum rb : RunLogBizTypeEnum.values()) {
			if (rb.getBcode() == code) {
				return rb;
			}
		}
		return null;
	}
}
